import java.util.Scanner;

public class WeekDay {
    public static void  main(String[] args){
        System.out.println("请输入星期的第一个字母：");
        Scanner a = new Scanner(System.in);
        String b = a.nextLine();
        if (b.length() == 1){
            int c = b.charAt(0);
            switch (c) {
                case 'M', 'm' -> System.out.println("周一");
                case 'T', 't' -> {
                    String d = a.next();
                    if (a.hasNext()) {
                        int e = d.charAt(0);
                        if (e == 'U' || e == 'u') {
                            System.out.println("星期二");
                        } else {
                            System.out.println("星期四");
                        }
                    } else {
                        System.out.println("输入有误！");
                    }
                }
                case 'W', 'w' -> System.out.println("周三");
                case 'F', 'f' -> System.out.println("周五");
                case 'S', 's' -> {
                    String f = a.next();
                    if (a.hasNext()) {
                        int h = f.charAt(0);
                        if (h == 'a' || h == 'A') {
                            System.out.println("星期六");
                        } else {
                            System.out.println("星期天");
                        }
                    } else {
                        System.out.println("输入有误！");
                    }
                }
            }
        }else{
            System.out.println("输入有误！");
        }
    }


}
